package org.kyw.auth.service.impl;

import org.kyw.auth.domain.Menu;
import org.kyw.auth.mapper.MenuMapper;
import org.kyw.auth.service.IMenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Service
@Transactional(readOnly = true, propagation = Propagation.SUPPORTS)
public class MenuServiceImpl implements IMenuService {

    @Autowired
    private MenuMapper menuMapper;

    @Override
    public List<Menu> loadOneAndTwolevelMenuByEmpId(Long id) {
        return menuMapper.loadOneAndTwolevelMenuByEmpId(id);
    }
}
